package com.example.customviewtest.prize_game;

import android.content.Context;
import android.util.AttributeSet;
import android.widget.FrameLayout;

/**
 * @auther XuDan on 2020/6/22.
 */
public class MyBg extends FrameLayout {
    public MyBg(Context context) {
        this(context, null);
    }

    public MyBg(Context context, AttributeSet attrs) {
        this(context, attrs, 0);
    }

    public MyBg(Context context, AttributeSet attrs, int defStyleAttr) {
        super(context, attrs, defStyleAttr);
    }

    @Override
    protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
        super.onMeasure(widthMeasureSpec, heightMeasureSpec);
        setMeasuredDimension(widthMeasureSpec, widthMeasureSpec);
    }
}
